<?php
/**
 * 日志模型
 * 
 * @author Lee<a605333742@gmail.com>
 * @date    2018-07-03
 */
namespace app\admin\model;

use think\Model;
use think\Db;

class Log extends Model{
    protected $logModel;
    public function __construct($data = array()) {
        parent::__construct($data);
        $this->logModel=Db::name("Log");
    }
    
    /*
     * 添加单条日志记录
     * 
     * @parma array $condition 需要添加的日志信息
     * 
     * @return bool
     */
    public function addOneLog($condition){
        return $this->logModel->insert($condition);
    }
}